package cn.com.org.service;

import java.util.Date;
import java.util.List;
import java.util.UUID;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.mongodb.core.MongoTemplate;
import org.springframework.data.mongodb.core.query.BasicQuery;
import org.springframework.data.mongodb.core.query.Criteria;
import org.springframework.data.mongodb.core.query.Query;
import org.springframework.data.mongodb.core.query.Update;
import org.springframework.stereotype.Component;

import com.mongodb.BasicDBObject;
import com.mongodb.DBObject;
import com.mongodb.WriteResult;
import com.mongodb.util.JSON;

import cn.com.bean.Employees;
import cn.com.common.EncryptUtil;
import cn.com.org.cinterface.IServiceBase;

@SuppressWarnings("hiding")
@Component
public class EmployeeService extends ServiceBaseImpl {
	
	 public EmployeeService(){
		 
	 }
	 public Boolean validateUser(String uname,String upwd){
		 
		 upwd = EncryptUtil.EncryptMd5OrSHA(upwd, "MD5");
			Boolean result = isExists("logname", uname,
					"password", upwd, Employees.class);
		 return result;
	 }
}
